package com.hgw.Demo07_ObserverPattern.Exercises22_9_5;

/**
 * Data time:2021/12/19 18:18
 * StudentID:2019112118
 * Author:hgw
 * Description:
 */
public class Client {
    public static void main(String[] args) {
        Department department = new Department("计算机");
        Student stu1,stu2;
        Teacher t1;
        stu1 = new Student("黄龚伟");
        stu2 = new Student("胡良玉");
        t1 = new Teacher("姜飞");

        department.attach(stu1);
        department.attach(stu2);
        department.attach(t1);
        System.out.println("==================================");
        department.notifyPeople("信息工程");
    }
}
